#ifndef _CkSocket_H
#define _CkSocket_H
#include "Chilkat_C.h"

HCkSocket CkSocket_Create(void);
void CkSocket_Dispose(HCkSocket handle);
BOOL CkSocket_getAsyncAcceptFinished(HCkSocket handle);
void CkSocket_getAsyncAcceptLog(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncAcceptSuccess(HCkSocket handle);
BOOL CkSocket_getAsyncConnectFinished(HCkSocket handle);
void CkSocket_getAsyncConnectLog(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncConnectSuccess(HCkSocket handle);
BOOL CkSocket_getAsyncDnsFinished(HCkSocket handle);
void CkSocket_getAsyncDnsLog(HCkSocket handle, HCkString retval);
void CkSocket_getAsyncDnsResult(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncDnsSuccess(HCkSocket handle);
BOOL CkSocket_getAsyncReceiveFinished(HCkSocket handle);
void CkSocket_getAsyncReceiveLog(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncReceiveSuccess(HCkSocket handle);
void CkSocket_getAsyncReceivedBytes(HCkSocket handle, HCkByteData retval);
void CkSocket_getAsyncReceivedString(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncSendFinished(HCkSocket handle);
void CkSocket_getAsyncSendLog(HCkSocket handle, HCkString retval);
BOOL CkSocket_getAsyncSendSuccess(HCkSocket handle);
long CkSocket_getConnectFailReason(HCkSocket handle);
long CkSocket_getDebugConnectDelayMs(HCkSocket handle);
void CkSocket_putDebugConnectDelayMs(HCkSocket handle, long newVal);
long CkSocket_getDebugDnsDelayMs(HCkSocket handle);
void CkSocket_putDebugDnsDelayMs(HCkSocket handle, long newVal);
long CkSocket_getHeartbeatMs(HCkSocket handle);
void CkSocket_putHeartbeatMs(HCkSocket handle, long newVal);
BOOL CkSocket_getIsConnected(HCkSocket handle);
BOOL CkSocket_getKeepSessionLog(HCkSocket handle);
void CkSocket_putKeepSessionLog(HCkSocket handle, BOOL newVal);
void CkSocket_getLastErrorHtml(HCkSocket handle, HCkString retval);
void CkSocket_getLastErrorText(HCkSocket handle, HCkString retval);
void CkSocket_getLastErrorXml(HCkSocket handle, HCkString retval);
long CkSocket_getMaxReadIdleMs(HCkSocket handle);
void CkSocket_putMaxReadIdleMs(HCkSocket handle, long newVal);
long CkSocket_getMaxSendIdleMs(HCkSocket handle);
void CkSocket_putMaxSendIdleMs(HCkSocket handle, long newVal);
void CkSocket_getMyIpAddress(HCkSocket handle, HCkString retval);
long CkSocket_getObjectId(HCkSocket handle);
long CkSocket_getReceivePacketSize(HCkSocket handle);
void CkSocket_putReceivePacketSize(HCkSocket handle, long newVal);
void CkSocket_getRemoteIpAddress(HCkSocket handle, HCkString retval);
long CkSocket_getRemotePort(HCkSocket handle);
long CkSocket_getSendPacketSize(HCkSocket handle);
void CkSocket_putSendPacketSize(HCkSocket handle, long newVal);
void CkSocket_getSessionLog(HCkSocket handle, HCkString retval);
void CkSocket_getSessionLogEncoding(HCkSocket handle, HCkString retval);
void CkSocket_putSessionLogEncoding(HCkSocket handle, const char *newVal);
BOOL CkSocket_getSsl(HCkSocket handle);
void CkSocket_putSsl(HCkSocket handle, BOOL newVal);
void CkSocket_getSslProtocol(HCkSocket handle, HCkString retval);
void CkSocket_putSslProtocol(HCkSocket handle, const char *newVal);
void CkSocket_getStringCharset(HCkSocket handle, HCkString retval);
void CkSocket_putStringCharset(HCkSocket handle, const char *newVal);
BOOL CkSocket_getUtf8(HCkSocket handle);
void CkSocket_putUtf8(HCkSocket handle, BOOL newVal);
void CkSocket_getVersion(HCkSocket handle, HCkString retval);
HCkSocket CkSocket_AcceptNextConnection(HCkSocket handle, int maxWaitMs);
void CkSocket_AsyncAcceptAbort(HCkSocket handle);
HCkSocket CkSocket_AsyncAcceptSocket(HCkSocket handle);
BOOL CkSocket_AsyncAcceptStart(HCkSocket handle, int maxWaitMs);
void CkSocket_AsyncConnectAbort(HCkSocket handle);
BOOL CkSocket_AsyncConnectStart(HCkSocket handle, const char *hostname, int port, BOOL ssl, int maxWaitMs);
void CkSocket_AsyncDnsAbort(HCkSocket handle);
BOOL CkSocket_AsyncDnsStart(HCkSocket handle, const char *hostname, int maxWaitMs);
void CkSocket_AsyncReceiveAbort(HCkSocket handle);
BOOL CkSocket_AsyncReceiveBytes(HCkSocket handle);
BOOL CkSocket_AsyncReceiveBytesN(HCkSocket handle, unsigned long numBytes);
BOOL CkSocket_AsyncReceiveString(HCkSocket handle);
BOOL CkSocket_AsyncReceiveToCRLF(HCkSocket handle);
BOOL CkSocket_AsyncReceiveUntilMatch(HCkSocket handle, const char *matchStr);
void CkSocket_AsyncSendAbort(HCkSocket handle);
BOOL CkSocket_AsyncSendBytes(HCkSocket handle, const unsigned char *byteData, unsigned long numBytes);
BOOL CkSocket_AsyncSendString(HCkSocket handle, const char *str);
BOOL CkSocket_BindAndListen(HCkSocket handle, int port, int backlog);
void CkSocket_BuildHttpGetRequest(HCkSocket handle, const char *url, HCkString str);
void CkSocket_ClearSessionLog(HCkSocket handle);
void CkSocket_Close(HCkSocket handle, int maxWaitMs);
BOOL CkSocket_Connect(HCkSocket handle, const char *hostname, int port, BOOL ssl, int maxWaitMs);
BOOL CkSocket_DnsLookup(HCkSocket handle, const char *hostname, int maxWaitMs, HCkString outStr);
HCkCert CkSocket_GetMyCert(HCkSocket handle);
HCkCert CkSocket_GetSslServerCert(HCkSocket handle);
BOOL CkSocket_InitSslServer(HCkSocket handle, HCkCert cert);
BOOL CkSocket_IsUnlocked(HCkSocket handle);
BOOL CkSocket_ReceiveBytes(HCkSocket handle, HCkByteData byteData);
BOOL CkSocket_ReceiveBytesN(HCkSocket handle, unsigned long numBytes, HCkByteData byteData);
BOOL CkSocket_ReceiveString(HCkSocket handle, HCkString strOut);
BOOL CkSocket_ReceiveStringMaxN(HCkSocket handle, int maxBytes, HCkString outStr);
BOOL CkSocket_ReceiveStringUntilByte(HCkSocket handle, int byteValue, HCkString outStr);
BOOL CkSocket_ReceiveToCRLF(HCkSocket handle, HCkString outStr);
BOOL CkSocket_ReceiveUntilByte(HCkSocket handle, int byteValue, HCkByteData outBytes);
BOOL CkSocket_ReceiveUntilMatch(HCkSocket handle, const char *matchStr, HCkString strOut);
BOOL CkSocket_SaveLastError(HCkSocket handle, const char *filename);
BOOL CkSocket_SendBytes(HCkSocket handle, const unsigned char *byteData, unsigned long numBytes);
BOOL CkSocket_SendString(HCkSocket handle, const char *str);
void CkSocket_SetSslClientCert(HCkSocket handle, HCkCert cert);
void CkSocket_SleepMs(HCkSocket handle, int millisec);
BOOL CkSocket_UnlockComponent(HCkSocket handle, const char *code);
const char *CkSocket_asyncAcceptLog(HCkSocket handle);
const char *CkSocket_asyncConnectLog(HCkSocket handle);
const char *CkSocket_asyncDnsLog(HCkSocket handle);
const char *CkSocket_asyncDnsResult(HCkSocket handle);
const char *CkSocket_asyncReceiveLog(HCkSocket handle);
const char *CkSocket_asyncReceivedString(HCkSocket handle);
const char *CkSocket_asyncSendLog(HCkSocket handle);
const char *CkSocket_buildHttpGetRequest(HCkSocket handle, const char *url);
const char *CkSocket_dnsLookup(HCkSocket handle, const char *hostname, int maxWaitMs);
const char *CkSocket_lastErrorHtml(HCkSocket handle);
const char *CkSocket_lastErrorText(HCkSocket handle);
const char *CkSocket_lastErrorXml(HCkSocket handle);
const char *CkSocket_myIpAddress(HCkSocket handle);
const char *CkSocket_receiveString(HCkSocket handle);
const char *CkSocket_receiveStringMaxN(HCkSocket handle, int maxBytes);
const char *CkSocket_receiveStringUntilByte(HCkSocket handle, int byteValue);
const char *CkSocket_receiveToCRLF(HCkSocket handle);
const char *CkSocket_receiveUntilMatch(HCkSocket handle, const char *matchStr);
const char *CkSocket_remoteIpAddress(HCkSocket handle);
const char *CkSocket_sessionLog(HCkSocket handle);
const char *CkSocket_sessionLogEncoding(HCkSocket handle);
const char *CkSocket_sslProtocol(HCkSocket handle);
const char *CkSocket_stringCharset(HCkSocket handle);
const char *CkSocket_version(HCkSocket handle);
#endif
